for (var i=9;i>=1;i--){
    var result="";
    for (var j=1;j<=i;j++){
        result+=(j+"*"+i+"="+i*j)+(i*j<10?"   ":"  ");
    }
    console.log(result);
}

